package com.barbeque.mall.mapper;

import com.barbeque.mall.bean.goods.MarketGoods;
import com.barbeque.mall.bean.goods.MarketGoodsExample;
import com.barbeque.mall.bean.goods.vo.CatAndBrandVO;
import com.barbeque.mall.bean.wx.topic.WxMarketTopicGoods;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface MarketGoodsMapper {
    long countByExample(MarketGoodsExample example);

    int deleteByExample(MarketGoodsExample example);

    int deleteByPrimaryKey(Integer id);

    int insert(MarketGoods record);

    int insertSelective(MarketGoods record);

    List<MarketGoods> selectByExampleWithBLOBs(MarketGoodsExample example);

    List<MarketGoods> selectByExample(MarketGoodsExample example);

    Integer selectCategoryIdByPrimaryKey(Integer id);

    MarketGoods selectByPrimaryKey(Integer id);

    WxMarketTopicGoods selectWxByPrimaryKey(Integer id);

    List<CatAndBrandVO.BrandListBean> selectIdAndNameOfBrand();

    List<CatAndBrandVO.CategoryListBean> selectIdAndNameOfCategory();

    List<CatAndBrandVO.CategoryListBean.ChildrenBean> selectIdAndNameOfCategoryByPid(Integer pid);

    int updateByExampleSelective(@Param("record") MarketGoods record, @Param("example") MarketGoodsExample example);

    int updateByExampleWithBLOBs(@Param("record") MarketGoods record, @Param("example") MarketGoodsExample example);

    int updateByExample(@Param("record") MarketGoods record, @Param("example") MarketGoodsExample example);

    int updateByPrimaryKeySelective(MarketGoods record);

    int updateByPrimaryKeyWithBLOBs(MarketGoods record);

    int updateByPrimaryKey(MarketGoods record);

}